package com.gzhryc.net_marketing.cloud.business.dao.db;

import java.util.Date;

import com.gzhryc.common.NumberTools;
import com.gzhryc.jdbc.annotaion.Column;
import com.gzhryc.jdbc.annotaion.PrimaryKey;
import com.gzhryc.jdbc.annotaion.Table;
import com.gzhryc.net_marketing.cloud.business.dao.enums.TeamPayApplyMemberEnum;
import com.gzhryc.shared_device.base.enums.EPayType;

@Table(name = "team_pay_apply_member")
public class TeamPayApplyMember {

	@PrimaryKey
	@Column(name = "apply_id")
	protected Long applyId;

	@PrimaryKey
	@Column(name = "member_id")
	protected Long memberId;

	@Column(name = "member_nickname",note = "会员昵称")
	protected String memberNickname;

	@Column(name = "member_phone",note = "会员手机号")
	protected String memberPhone;

	@Column(name = "member_face_img", length = 255)
	protected String memberFaceImg;

	@Column(name = "role_type",notNull = true,defVal = "1",note = "角色类型")
	protected Integer roleType;

	@Column(name = "goods_id", note = "商品ID，冗余字段")
	protected Long goodsId;

	@Column(name = "goods_name",notNull = true,length = 64)
	protected String goodsName;

	@Column(name="goods_classify",notNull = true,defVal = "1",note = "商品类型，1：实物，2：虚拟")
	protected Integer goodsClassify;

	@Column(name="goods_type_codes",length = 255)
	protected String goodsTypeCodes;

	@Column(name="goods_type_names",length = 255)
	protected String goodsTypeNames;

	@Column(name = "goods_img", length = 128)
	protected String goodsImg;

	@Column(name = "goods_space_id",note="规格参数ID")
	protected Long goodsSpaceId;

	@Column(name = "goods_space_name",note="规格参数名称")
	protected String goodsSpaceName;

	@Column(name = "goods_count",notNull = true,defVal = "1",note = "购买商品数量")
	protected Integer goodsCount;

	@Column(name = "goods_money",note="单个商品零售价格")
	protected Integer goodsMoney;

	@Column(length = 128,note = "客户备注")
	protected String note;

	@Column
	protected Integer priority;

	@Column(name = "business_trade_no",length = 32, note = "业务订单号")
	protected String businessTradeNo;

	@Column(name = "pay_trade_no", note = "当前支付订单，冗余辅助字段")
	protected String payTradeNo;

	@Column(name = "pay_type", note = "支付类型")
	protected Integer payType;

	@Column(name = "logistics_money", notNull = true,defVal = "0",note = "物流费用，单位：分")
	protected Integer logisticsMoney;

	@Column(name = "pay_money", notNull = true, note = "支付金额（单个商品的团拼价格x商品数量+物流费用），单位：分")
	protected Integer payMoney;

	@Column(name = "pay_state", notNull = true,defVal = "1", note = "支付状态")
	protected Integer payState;

	@Column(name = "reward_money", note = "奖励金额，单位：分")
	protected Integer rewardMoney;

	@Column(name = "mail_address_id")
	protected Long mailAddressId;

	@Column(name = "receive_name")
	protected String receiveName;

	@Column(name = "receive_phone")
	protected String receivePhone;

	@Column(name = "receive_province",note="收货地址省份")
	protected String receiveProvince;

	@Column(name = "receive_address", length = 255)
	protected String receiveAddress;

	@Column(name = "logistics_company_id",note="物流公司ID，用户指定或当时默认物流")
	protected String logisticsCompanyId;

	@Column(name = "logistics_company",note="物流公司")
	protected String logisticsCompany;

	@Column
	protected Integer state;

	@Column(name = "close_reason", length = 64,note = "关闭原因")
	protected String closeReason;

	@Column(name = "update_date", autoUpdateTime = true)
	protected Date updateDate;

	@Column(name = "create_date")
	protected Date createDate;

	public Long getApplyId() {
		return applyId;
	}

	public void setApplyId(Long applyId) {
		this.applyId = applyId;
	}

	public Long getMemberId() {
		return memberId;
	}

	public void setMemberId(Long memberId) {
		this.memberId = memberId;
	}

	public String getMemberNickname() {
		return memberNickname;
	}

	public void setMemberNickname(String memberNickname) {
		this.memberNickname = memberNickname;
	}

	public String getMemberPhone() {
		return memberPhone;
	}

	public void setMemberPhone(String memberPhone) {
		this.memberPhone = memberPhone;
	}

	public String getMemberFaceImg() {
		return memberFaceImg;
	}

	public void setMemberFaceImg(String memberFaceImg) {
		this.memberFaceImg = memberFaceImg;
	}

	public Integer getRoleType() {
		return roleType;
	}

	public void setRoleType(Integer roleType) {
		this.roleType = roleType;
	}

	public Long getGoodsId() {
		return goodsId;
	}

	public void setGoodsId(Long goodsId) {
		this.goodsId = goodsId;
	}

	public Long getGoodsSpaceId() {
		return goodsSpaceId;
	}

	public void setGoodsSpaceId(Long goodsSpaceId) {
		this.goodsSpaceId = goodsSpaceId;
	}

	public String getGoodsSpaceName() {
		return goodsSpaceName;
	}

	public void setGoodsSpaceName(String goodsSpaceName) {
		this.goodsSpaceName = goodsSpaceName;
	}

	public Integer getGoodsCount() {
		return goodsCount;
	}

	public void setGoodsCount(Integer goodsCount) {
		this.goodsCount = goodsCount;
	}

	public String getGoodsName() {
		return goodsName;
	}

	public void setGoodsName(String goodsName) {
		this.goodsName = goodsName;
	}

	public Integer getGoodsClassify() {
		return goodsClassify;
	}

	public void setGoodsClassify(Integer goodsClassify) {
		this.goodsClassify = goodsClassify;
	}

	public String getGoodsTypeCodes() {
		return goodsTypeCodes;
	}

	public void setGoodsTypeCodes(String goodsTypeCodes) {
		this.goodsTypeCodes = goodsTypeCodes;
	}

	public String getGoodsTypeNames() {
		return goodsTypeNames;
	}

	public void setGoodsTypeNames(String goodsTypeNames) {
		this.goodsTypeNames = goodsTypeNames;
	}

	public String getGoodsImg() {
		return goodsImg;
	}

	public void setGoodsImg(String goodsImg) {
		this.goodsImg = goodsImg;
	}

	public Integer getGoodsMoney() {
		return goodsMoney;
	}

	public void setGoodsMoney(Integer goodsMoney) {
		this.goodsMoney = goodsMoney;
	}

	public String getNote() {
		return note;
	}

	public void setNote(String note) {
		this.note = note;
	}

	public Integer getPriority() {
		return priority;
	}

	public void setPriority(Integer priority) {
		this.priority = priority;
	}

	public String getBusinessTradeNo() {
		return businessTradeNo;
	}

	public void setBusinessTradeNo(String businessTradeNo) {
		this.businessTradeNo = businessTradeNo;
	}

	public String getPayTradeNo() {
		return payTradeNo;
	}

	public void setPayTradeNo(String payTradeNo) {
		this.payTradeNo = payTradeNo;
	}

	public Integer getPayType() {
		return payType;
	}

	public void setPayType(Integer payType) {
		this.payType = payType;
	}

	public Integer getLogisticsMoney() {
		return logisticsMoney;
	}

	public void setLogisticsMoney(Integer logisticsMoney) {
		this.logisticsMoney = logisticsMoney;
	}

	public Integer getPayMoney() {
		return payMoney;
	}

	public void setPayMoney(Integer payMoney) {
		this.payMoney = payMoney;
	}

	public Integer getPayState() {
		return payState;
	}

	public void setPayState(Integer payState) {
		this.payState = payState;
	}

	public Integer getRewardMoney() {
		return rewardMoney;
	}

	public void setRewardMoney(Integer rewardMoney) {
		this.rewardMoney = rewardMoney;
	}

	public Long getMailAddressId() {
		return mailAddressId;
	}

	public void setMailAddressId(Long mailAddressId) {
		this.mailAddressId = mailAddressId;
	}

	public String getReceiveName() {
		return receiveName;
	}

	public void setReceiveName(String receiveName) {
		this.receiveName = receiveName;
	}

	public String getReceivePhone() {
		return receivePhone;
	}

	public void setReceivePhone(String receivePhone) {
		this.receivePhone = receivePhone;
	}

	public String getReceiveProvince() {
		return receiveProvince;
	}

	public void setReceiveProvince(String receiveProvince) {
		this.receiveProvince = receiveProvince;
	}

	public String getReceiveAddress() {
		return receiveAddress;
	}

	public void setReceiveAddress(String receiveAddress) {
		this.receiveAddress = receiveAddress;
	}

	public String getLogisticsCompanyId() {
		return logisticsCompanyId;
	}

	public void setLogisticsCompanyId(String logisticsCompanyId) {
		this.logisticsCompanyId = logisticsCompanyId;
	}

	public String getLogisticsCompany() {
		return logisticsCompany;
	}

	public void setLogisticsCompany(String logisticsCompany) {
		this.logisticsCompany = logisticsCompany;
	}

	public String getCloseReason() {
		return closeReason;
	}

	public void setCloseReason(String closeReason) {
		this.closeReason = closeReason;
	}

	public Integer getState() {
		return state;
	}

	public void setState(Integer state) {
		this.state = state;
	}

	public Date getUpdateDate() {
		return updateDate;
	}

	public void setUpdateDate(Date updateDate) {
		this.updateDate = updateDate;
	}

	public Date getCreateDate() {
		return createDate;
	}

	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

	public String getStateName() {
		return TeamPayApplyMemberEnum.State.note(this.state);
	}

	public String getPayStateName() {
		return TeamPayApplyMemberEnum.PayState.note(this.payState);
	}

	public String getPayTypeName() {
		return EPayType.note(this.payType);
	}

	public String getGoodsMoneyStr() {
		return NumberTools.getMoneyStr(this.goodsMoney);
	}

	public String getPayMoneyStr() {
		return NumberTools.getMoneyStr(this.payMoney);
	}

	public String getRewardMoneyStr() {
		return NumberTools.getMoneyStr(this.rewardMoney);
	}

	public String getLogisticsMoneyStr() {
		return NumberTools.getMoneyStr(this.logisticsMoney);
	}

	public String getRoleTypeName(){
		return TeamPayApplyMemberEnum.RoleType.note(this.roleType);
	}
}
